﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace DJY.Domain.Entity.WorkFlow
{
    /// <summary>
    /// 节点操作人 实体
    /// </summary>
    public class WFNodeUserEntity
    {
        /// <summary>
        /// 流程节点
        /// </summary>
		[StringLength(36)]
    	public string NodeId
    	{
    		get;
    		set;
    	}
        
        /// <summary>
        /// 用户id
        /// </summary>
		[StringLength(36)]
    	public string UserId
    	{
    		get;
    		set;
    	}

        /// <summary>
        /// 用户名称
        /// </summary>
		[StringLength(100)]
        public string UserName
        {
            get;
            set;
        }

        /// <summary>
        /// 用户类型：0用户，1角色
        /// </summary>
        public int UserType
    	{
    		get;
    		set;
    	}
        
        /// <summary>
        /// 是否为候选
        /// </summary>
    	public bool IsCandidate
    	{
    		get;
    		set;
    	}
        
        /// <summary>
        /// 流程ID，冗余字段
        /// </summary>
		[StringLength(36)]
    	public string WFID
    	{
    		get;
    		set;
    	}
        
        /// <summary>
        /// 记录id,必须要有一个主键，否则EF无法使用
        /// </summary>
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
    	public long Id
    	{
    		get;
    		set;
    	}
        
    }
}
